package com.forekenow.oop;

public class ConstructorDemo {
    private String name;
    private int age;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public ConstructorDemo(String name, int age){
        this.name = "fender";
        this.age = 23;
        Student[] students = new Student[10];
        System.out.println("这是一个构造器....");
    }
    public static void main(String[] args) {
        ConstructorDemo constructorDemo = new ConstructorDemo("fender",23);
        System.out.println(constructorDemo.getAge()+constructorDemo.getName());
    }
}
